package net.cyndeline.itemEventFactory.conditions

import net.cyndeline.entitySystem.EntityRef
import net.cyndeline.itemEventFactory.Action
import net.cyndeline.stateEvaluation.PropertyCondition
import net.cyndeline.stateEvaluation.Evaluator

/**
 * Examines a single entity, and checks if it fulfills a
 * specified criteria.
 */
trait Condition extends Action {
  
  /**
   * @return The number of targets that must fulfill the condition in
   * 		 order for it to validate. Default is 0.
   */
  def amount: Int
  
  /**
   * Sets a new number of targets that must be present and fulfill
   * the condition.
   */
  def amount_=(newAmount: Int)
  
  /**
   * Adds an evaluator that filters entities based on their properties.
   */
  def addEvaluator(evaluator: Evaluator*)
  
  /**
   * Adds an action that should return events upon indata.
   */
  def addAction(action: Action*)
  
  
  def setChance() {} // TODO implement
  def addSelector() {} // TODO implement
  
  
}